import Vue from 'vue';
import VueRouter from 'vue-router';
Vue.use(VueRouter);
const routes = [
  {
    path: '/',
    component: () => import('@p/Layout.vue'),  
    children: [
      {
        path: '',
        component: () => import('@p/Home.vue'),
      },
      {
        path: 'home',
        component: () => import('@p/Home.vue'),
      },
      {
        path: 'news',
        component: () => import('@p/News.vue'),
      }
    ]
  },
]
const router = new VueRouter({
  routes,
  mode: 'history'
}) 

export default router;